package com.ljt.kotlinandmvvm.main.fragment

import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.databinding.DataBindingUtil
import androidx.fragment.app.Fragment
import com.ljt.base.fragment.BaseFragment
import com.ljt.kotlinandmvvm.R
import com.ljt.kotlinandmvvm.databinding.FragmentFirstBinding
import kotlinx.android.synthetic.main.draw_module_title.view.*

/**
 * @auther :lujiantao
 * @date :2024/4/28 4:51 PM
 * @desc :首页
 */
class FirstFragment: BaseFragment() {

    private lateinit var binding: FragmentFirstBinding

    companion object{
        fun newInstance() = FirstFragment()
    }

    override fun onCreateView(
        inflater: LayoutInflater,
        container: ViewGroup?,
        savedInstanceState: Bundle?
    ): View? {
        binding = FragmentFirstBinding.inflate(layoutInflater) // 缺失的是这一行
        initView()
        return binding.root
    }


     fun initView() {
        if (binding != null) {
            binding.ilModuleTitle.tvModuleTitle.text = "首页"
            binding.ilModuleTitle.ivModuleBack.visibility = View.GONE
        }
    }
}